﻿using System;

namespace Mono.Cecil
{
	// Token: 0x020000B8 RID: 184
	public abstract class ParameterReference : IMetadataTokenProvider
	{
		// Token: 0x170001F9 RID: 505
		// (get) Token: 0x06000790 RID: 1936 RVA: 0x00023650 File Offset: 0x00021850
		// (set) Token: 0x06000791 RID: 1937 RVA: 0x00004B0E File Offset: 0x00002D0E
		public string Name
		{
			get
			{
				return this.name;
			}
			set
			{
				this.name = value;
			}
		}

		// Token: 0x170001FA RID: 506
		// (get) Token: 0x06000792 RID: 1938 RVA: 0x00023668 File Offset: 0x00021868
		public int Index
		{
			get
			{
				return this.index;
			}
		}

		// Token: 0x170001FB RID: 507
		// (get) Token: 0x06000793 RID: 1939 RVA: 0x00023680 File Offset: 0x00021880
		// (set) Token: 0x06000794 RID: 1940 RVA: 0x00004B18 File Offset: 0x00002D18
		public TypeReference ParameterType
		{
			get
			{
				return this.parameter_type;
			}
			set
			{
				this.parameter_type = value;
			}
		}

		// Token: 0x170001FC RID: 508
		// (get) Token: 0x06000795 RID: 1941 RVA: 0x00023698 File Offset: 0x00021898
		// (set) Token: 0x06000796 RID: 1942 RVA: 0x00004B22 File Offset: 0x00002D22
		public MetadataToken MetadataToken
		{
			get
			{
				return this.token;
			}
			set
			{
				this.token = value;
			}
		}

		// Token: 0x06000797 RID: 1943 RVA: 0x000236B0 File Offset: 0x000218B0
		internal ParameterReference(string name, TypeReference parameterType)
		{
			bool flag = parameterType == null;
			if (flag)
			{
				throw new ArgumentNullException("parameterType");
			}
			this.name = (name ?? string.Empty);
			this.parameter_type = parameterType;
		}

		// Token: 0x06000798 RID: 1944 RVA: 0x00023650 File Offset: 0x00021850
		public override string ToString()
		{
			return this.name;
		}

		// Token: 0x06000799 RID: 1945
		public abstract ParameterDefinition Resolve();

		// Token: 0x0400028C RID: 652
		private string name;

		// Token: 0x0400028D RID: 653
		internal int index = -1;

		// Token: 0x0400028E RID: 654
		protected TypeReference parameter_type;

		// Token: 0x0400028F RID: 655
		internal MetadataToken token;
	}
}
